//
//  EDSVideoCropView.h
//  DrivieSchoolStudents
//
//  Created by TangBin on 2019/5/27.
//  Copyright © 2019 班文政. All rights reserved.
//

#import "TYZBaseView.h"
#import <MediaPlayer/MediaPlayer.h>

NS_ASSUME_NONNULL_BEGIN

#define kEDSVideoCropViewHeight  (50.0)


@protocol EDSVideoCropViewDelegate <NSObject>

/**
 得到当前播放的时间
 
 @return return value description
 */
- (CMTimeScale)getCurrentTime;


@optional

/**
  启动定时器
 */
- (void)startTimes;

/**
 停止定时器
 */
- (void)stopTimes;

- (void)seekTotime:(CMTime)time withBefore:(CMTime)before withAfter:(CMTime)after;

@end


@interface EDSVideoCropView : TYZBaseView

@property (nonatomic, assign, readonly) CGFloat   startTime;      ///< 编辑框内视频开始时间秒
@property (nonatomic, assign, readonly) CGFloat   endTime;        ///< 编辑框内视频结束时间秒
@property (nonatomic, assign, readonly) CGFloat   startPointX;    ///< 编辑框起始点
@property (nonatomic, assign, readonly) CGFloat   endPointX;      ///< 编辑框结束点

@property (nonatomic, weak) id<EDSVideoCropViewDelegate> delegate;


- (instancetype)initWithFrame:(CGRect)frame seconds:(NSInteger)seconds;

- (void)addImageFrame:(long)count image:(UIImage *)image;


- (void)startTimer;

- (void)stopTimer;

@end

NS_ASSUME_NONNULL_END
